$(document).ready(function (){
    var baseurl = $('#baseurl').val();
    $('.submitComment').submit(function (){
        $.ajax({
            url: baseurl + '/index.php/hoidap/hoidap/add_comment',
            data: $('form').serialize(),
            type: 'POST',
            success: function (comment){
                if ($(comment).text()=="")
                {
                    $('#attention').show();
                }
                else
                {
                    $('#attention').hide();
                    $(comment).hide().insertAfter('#insertBeforeMe').slideDown('slow');
                    $('#comment_noidung').val("");
                }
            }
        })
        return false;
    })
})